package com.quanyan.place.service;

import com.quanyan.api.APIResponse;
import com.quanyan.common.Plugin.PageObj;
import com.quanyan.place.entity.Dict;
import com.quanyan.place.entity.TbCity;
import com.quanyan.place.entity.TbCommonParameter;
import com.quanyan.place.entity.TbProvince;
import com.quanyan.place.entity.apireq.ReqCity;
import com.quanyan.place.entity.apireq.ReqKeyWords;
import com.quanyan.place.entity.vo.ReqBaseSearch;

import java.util.List;
import java.util.Map;

/**
 * Created by yangyun on 2016/5/20.
 */
public interface BaseService {

    PageObj<List<TbProvince>> getProvinceList(Integer pageNum, Integer pageSize, String keyWords);

    PageObj<List<TbCity>> getCityList(Integer provinceId,Integer pageNum, Integer pageSize, String keyWords);

    PageObj<List<TbCommonParameter>> getSysParameterList(ReqBaseSearch reqBaseSearch);

    Integer getPlaceSearchType();

    TbCity getCityById(Integer cityId);

    //APIResponse<?> getCitys(Integer prosaveOrUpdateSysParametervinceId, boolean isActive, double lng, double lat);
    APIResponse saveOrUpdateSysParameter(TbCommonParameter sysParameter);

    APIResponse sysParameterDelete(Integer id);

    Map<String,String> getPlaceOrderRule();

    TbCommonParameter getParameterByKey(String key);

    /**
     * 取得GPS定位到用户位置与场馆位置距离
     * @return
     */
     Double getPlaceRecommendArea();

    APIResponse saveCity(ReqCity reqCity);

    APIResponse updateCity(ReqCity reqCity);

    /*********** 字典数据表  维护接口 ****************/

    /**
     * 获取字典数据列表
     */
    PageObj<List<Dict>> getDicts(ReqKeyWords reqKeyWords);

    /**
     * 编辑字典数据
     */
    void editDict(Dict dict);

    /**
     * 删除数据字典
     */
    void deleteDict(int id);

    List<TbProvince> getProvinceListAdmin();


}
